package cn.diancan.model.types;

public enum PayType {


    unknow(0,"未知"),

    CASH(1,"现金"),

    weixin(2,"微信支付"),

    alipay(3,"支付宝"),

    card(4,"刷卡"),

    wmpt(5,"外卖平台"),

    wmdf(6,"外卖到付"),



    ;

    private PayType(Integer type, String typeName){
	this.type = type; 
	this.typeName=typeName;
    }
    
    public static boolean checkExists(Integer type){
	if(null==type){
	    return false;
	}
	PayType enums[] = PayType.values();
	for (int i = 0; i < enums.length; i++) {
	    PayType singleEnum=  enums[i];
	    if(singleEnum.getType().equals(type)){
		return true;
	    }
	}
	return false;
    }
    
    private Integer type;
    private String typeName;
    public Integer getType() {
        return type;
    }
    public String getTypeName() {
        return typeName;
    }
}
